//package com.bootdo.screen.controller;
//
//import com.alibaba.fastjson.JSON;
//import com.bootdo.screen.domain.DataclassesDO;
//import com.bootdo.screen.service.*;
//import com.bootdo.screen.service.impl.EnergyDataServiceImpl;
//import com.bootdo.screen.service.impl.PsDataServiceImpl;
//import com.bootdo.system.service.SessionService;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.messaging.simp.SimpMessagingTemplate;
//import org.springframework.scheduling.annotation.Scheduled;
//import org.springframework.stereotype.Controller;
//import org.springframework.web.bind.annotation.RestController;
//
//import java.util.*;
//
//@RestController
//public class WebSocketController {
//	@Autowired
//	SimpMessagingTemplate template;
//
//	@Autowired
//	EnergyDataServiceImpl energyDataService;
//
//	@Autowired
//	PsDataServiceImpl psDataService;
//
//	/**
//	 * 能源搜索接口
//	 */
//
//	// 数据分类
//	@Scheduled(fixedRate = 1000)
//	public void  getDataClasses() {
//		Map<String, Object> res = energyDataService.getDataClasses();
//		template.convertAndSend("/topic/getDataClasses",JSON.toJSONString(res));
//	}
//	// 热词
//	@Scheduled(fixedRate = 1000)
//	public void getHotWordCount() {
//		template.convertAndSend("/topic/getHotWordCount",JSON.toJSONString( energyDataService.getHotWordCount()));
//	}
//
//	//入库量
//	@Scheduled(fixedRate = 1000)
//	public void getTypeCount() {
//		template.convertAndSend("/topic/getTypeCount",JSON.toJSONString( energyDataService.getTypeCount()));
//	}
//   //业务类型
//	@Scheduled(fixedRate = 1000)
//	public void getBusinessCount() {
//		template.convertAndSend("/topic/getBusinessCount",JSON.toJSONString( energyDataService.getBusinessCount()));
//	}
//
//	//能源总量
//	@Scheduled(fixedRate = 1000)
//	public void getEnergyTotal() {
//		template.convertAndSend("/topic/getEnergyTotal",JSON.toJSONString( energyDataService.getEnergyTotal()));
//	}
//
//	//能源数据量
//	@Scheduled(fixedRate = 1000)
//	public void getSourceCount() {
//		template.convertAndSend("/topic/getSourceCount",JSON.toJSONString( energyDataService.getSourceCount()));
//	}
//	//昌平和迪拜数据量
//	@Scheduled(fixedRate = 1000)
//	public void getAreaCount() {
//		template.convertAndSend("/topic/getSourceCount",JSON.toJSONString( energyDataService.getAreaCount()));
//	}
//	/**
//	 * 舆情接口
//	 */
//	// 区域统计
//	@Scheduled(fixedRate = 1000)
//	public void getPsAreaCount() {
//		template.convertAndSend("/topic/getPsAreaCount",JSON.toJSONString( psDataService.getPsAreaCount()));
//	}
//	//数据来源统计  微信、微博
//	@Scheduled(fixedRate = 1000)
//	public void getPsSourceCount(){
//		template.convertAndSend("/topic/getPsSourceCount",JSON.toJSONString( psDataService.getPsSourceCount()));
//	}
//
//	//舆情网站采集量top10
//	@Scheduled(fixedRate = 1000)
//	public void getPsSiteTop(){
//		template.convertAndSend("/topic/getPsSiteTop",JSON.toJSONString( psDataService.getPsSiteTop()));
//	}
//
//	//舆情采集源列表
//	@Scheduled(fixedRate = 1000)
//	public void getPsSiteList(){ 	template.convertAndSend("/topic/getPsSiteList",JSON.toJSONString( psDataService.getPsSiteList()));}
//
//
//}